﻿<controls:ChildWindow x:Class="SLWebApp.ChildWindows.ChildWindow_VoyageAmount"
                      xmlns:toolkit="http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit" 
                      xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk" 
           xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
           xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
           xmlns:controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls"
            Width="800" Height="450" Loaded="ChildWindow_Loaded" Closing="ChildWindow_Closing"
           Title="航次箱量维护：" FontFamily="Comic Sans MS" FontSize="12">
    <toolkit:BusyIndicator x:Name="progressbar" IsBusy="False" >
        <Grid x:Name="LayoutRoot">
            <Grid.RowDefinitions>
                <RowDefinition Height="25" />
                <RowDefinition Height="5" />
                <RowDefinition  Height="Auto" />
                <RowDefinition  Height="Auto" />
            </Grid.RowDefinitions>
            <Grid.ColumnDefinitions>
                <ColumnDefinition />
                <ColumnDefinition Width="5" />
                <ColumnDefinition />
            </Grid.ColumnDefinitions>
            <!--//////////////////////////以下是集装箱的箱量////////////////////////-->
            <Border BorderThickness="1" Grid.Row="0" Grid.Column="0" BorderBrush="#b4b4b4" CornerRadius="1" >
                <TextBlock  FontSize="14" TextAlignment="Center" VerticalAlignment="Center" FontWeight="Bold">集装箱箱量</TextBlock>
            </Border>
            <StackPanel Grid.Row="2" Grid.Column="0" Height="Auto">
                <Border BorderThickness="1" Height="30" BorderBrush="#b4b4b4" CornerRadius="1" >
                    <Border.Background>
                        <ImageBrush ImageSource="/SLWebApp;component/img/operate_box_bg.png" />
                    </Border.Background>
                    <StackPanel  Orientation="Horizontal" HorizontalAlignment="Left" >
                        <TextBlock Text="操作：" Padding="10,6" Height="30" Width="50"/>
                        <Image Width="16" Height="16" Source="/SLWebApp;component/img/icon_save.png"></Image>
                        <TextBlock x:Name="btnSave_Container" MouseLeftButtonDown="btnSave_Container_MouseLeftButtonDown" Padding="3,6" Cursor="Hand">新增保存</TextBlock>
                        <TextBlock Padding="3,5">|</TextBlock>
                        <Image Width="16" Height="16" Source="/SLWebApp;component/img/icon_delete.png"></Image>
                        <TextBlock x:Name="btnContainer_Del" MouseLeftButtonDown="btnContainer_Del_MouseLeftButtonDown" Padding="3,6" Cursor="Hand">删除</TextBlock>
                        <TextBlock Padding="3,5">|</TextBlock>
                        <Image Width="16" Height="16" Source="/SLWebApp;component/img/Icon-Search.png"></Image>
                        <TextBlock MouseLeftButtonDown="btnContainer_Modefy_MouseLeftButtonDown" x:Name="btnContainer_Modefy" Padding="3,6" Cursor="Hand">修改保存</TextBlock>
                    </StackPanel>
                </Border>
                <Border Margin="0,5,0,0" BorderThickness="1" BorderBrush="#b4b4b4" CornerRadius="1" >
                    <Grid >
                        <Grid.RowDefinitions>
                            <RowDefinition Height="30" />
                            <RowDefinition Height="30"/>
                            <RowDefinition Height="30"/>
                        </Grid.RowDefinitions>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="80" />
                            <ColumnDefinition />
                            <ColumnDefinition Width="70"/>
                            <ColumnDefinition />
                            <ColumnDefinition Width="5" />
                        </Grid.ColumnDefinitions>
                        <TextBlock Padding="3,3" Height="22" Grid.Row="0" Grid.Column="0"  HorizontalAlignment="Right">箱尺寸：</TextBlock>
                        <ComboBox x:Name="comboxBoxSize"   Grid.Row="0" Grid.Column="1" Height="22">
                            <ComboBox.ItemTemplate>
                                <DataTemplate>
                                    <StackPanel Orientation="Horizontal">
                                        <TextBlock Text="{Binding Path=CSZ_CSIZENM}" Width="Auto" />
                                    </StackPanel>
                                </DataTemplate>
                            </ComboBox.ItemTemplate>
                        </ComboBox>

                        <TextBlock Padding="3,3" Height="22" Grid.Row="0" Grid.Column="2"  HorizontalAlignment="Right">箱状态：</TextBlock>
                        <ComboBox x:Name="comboxBoxStyle"   Grid.Row="0" Grid.Column="3" Height="22">
                            <ComboBox.ItemTemplate>
                                <DataTemplate>
                                    <StackPanel Orientation="Horizontal">
                                        <TextBlock Text="{Binding Path=STS_CSTATUSCD}" Width="Auto" />
                                    </StackPanel>
                                </DataTemplate>
                            </ComboBox.ItemTemplate>
                        </ComboBox>
                        <TextBlock Padding="3,3" Height="22" Grid.Row="1" Grid.Column="0"  HorizontalAlignment="Right">危险品等级：</TextBlock>
                        <ComboBox x:Name="comboxBoxLevel"   Grid.Row="1" Grid.Column="1" Height="22">
                            <ComboBox.ItemTemplate>
                                <DataTemplate>
                                    <StackPanel Orientation="Horizontal">
                                        <TextBlock Text="{Binding Path=DTP_DNGGNM}" Width="Auto" />
                                    </StackPanel>
                                </DataTemplate>
                            </ComboBox.ItemTemplate>
                        </ComboBox>

                        <TextBlock Padding="3,3" Height="22" Grid.Row="1" Grid.Column="2"  HorizontalAlignment="Right">超限：</TextBlock>
                        <ComboBox x:Name="comboxBoxOVLMTCD"   Grid.Row="1" Grid.Column="3" Height="22">
                            <ComboBox.ItemTemplate>
                                <DataTemplate>
                                    <StackPanel Orientation="Horizontal">
                                        <TextBlock Text="{Binding Path=RV_MEANING}" Width="Auto" />
                                    </StackPanel>
                                </DataTemplate>
                            </ComboBox.ItemTemplate>
                        </ComboBox>

                        <TextBlock Padding="3,3" Height="22" Grid.Row="2" Grid.Column="0"  HorizontalAlignment="Right">冷冻标志：</TextBlock>
                        <RadioButton Content="否" Name="rbtnN"  Grid.Row="2" GroupName="voyage"  Grid.Column="1" Height="16" HorizontalAlignment="Left" IsChecked="True"    />
                        <RadioButton Content="是" Name="rbtnY"  Grid.Row="2"  GroupName="voyage" Grid.Column="1" Height="16" HorizontalAlignment="Left"  Margin="40,0,0,0"   />

                        <TextBlock Padding="3,3" Height="22" Grid.Row="2" Grid.Column="1" Margin="80,0,-10,0"  HorizontalAlignment="Right">箱量：</TextBlock>
                        <TextBox x:Name="txtContainerAmount" Height="22" Grid.Row="2" Grid.Column="2" Margin="10,0,30,0" Grid.ColumnSpan="2" Width="30" HorizontalAlignment="Left"/>

                        <TextBlock Padding="3,3" Height="22" Grid.Row="2" Grid.Column="2" Margin="45,0,55,0" Grid.ColumnSpan="2" Width="62">空重标志：</TextBlock>
                        <ComboBox x:Name="comBoxEFfg" Height="22" Grid.Row="2" Grid.Column="2"  Grid.ColumnSpan="2" Margin="50,0,10,0" Width="50" HorizontalAlignment="Right">
                            <ComboBoxItem>E</ComboBoxItem>
                            <ComboBoxItem>F</ComboBoxItem>
                        </ComboBox>
                    </Grid>
                </Border>
                <Border Height="5" />
            </StackPanel>
            <sdk:DataGrid x:Name="dataGrid_CTNAmount" Grid.Row="3" Grid.Column="0" Height="Auto" MinHeight="250" MaxHeight="250" SelectionChanged="dataGrid_CTNAmount_SelectionChanged"  AutoGenerateColumns="False" HorizontalContentAlignment="Center">
                <sdk:DataGrid.Columns>
                    <sdk:DataGridTextColumn Header="箱尺寸" Binding="{Binding CSZ_CSIZENM}" Width="9*" IsReadOnly="True"/>
                    <sdk:DataGridTextColumn Header="箱型" Binding="{Binding VAT_STS_CSTATUSCD}" Width="8*" IsReadOnly="True"/>
                    <sdk:DataGridTextColumn Header="危险品等级" Binding="{Binding VAT_DNGFG}" Width="13*" IsReadOnly="True"/>
                    <sdk:DataGridTextColumn Header="超限" Binding="{Binding RV_MEANING}" Width="8*" IsReadOnly="True"/>
                    <sdk:DataGridTextColumn Header="冷冻标志" Binding="{Binding VAT_RFFG}" Width="12*" IsReadOnly="True"/>
                    <sdk:DataGridTextColumn Header="箱量" Binding="{Binding VAT_AMOUNT}" Width="8*" IsReadOnly="True"/>
                </sdk:DataGrid.Columns>
            </sdk:DataGrid>
            <!--//////////////////////////以下是散货箱的箱量////////////////////////-->
            <Border BorderThickness="1" Grid.Row="0" Grid.Column="2" BorderBrush="#b4b4b4" CornerRadius="1" >
                <TextBlock  FontSize="14" TextAlignment="Center" VerticalAlignment="Center" FontWeight="Bold">散货箱箱量</TextBlock>
            </Border>
            <StackPanel Grid.Row="2" Grid.Column="2" Height="Auto">
                <Border BorderThickness="1" Height="30" BorderBrush="#b4b4b4" CornerRadius="1" >
                    <Border.Background>
                        <ImageBrush ImageSource="/SLWebApp;component/img/operate_box_bg.png" />
                    </Border.Background>
                    <StackPanel  Orientation="Horizontal" HorizontalAlignment="Left" >
                        <TextBlock Text="操作：" Padding="10,6" Height="30" Width="50"/>
                        <Image Width="16" Height="16" Source="/SLWebApp;component/img/icon_save.png"></Image>
                        <TextBlock x:Name="btnBulk_Save" MouseLeftButtonDown="btnBulk_Save_MouseLeftButtonDown" Padding="3,6" Cursor="Hand">新增保存</TextBlock>
                        <TextBlock Padding="3,5">|</TextBlock>
                        <Image Width="16" Height="16" Source="/SLWebApp;component/img/icon_delete.png"></Image>
                        <TextBlock x:Name="btnBulk_Del" MouseLeftButtonDown="btnBulk_Del_MouseLeftButtonDown"  Padding="3,6" Cursor="Hand">删除</TextBlock>
                        <TextBlock Padding="3,5">|</TextBlock>
                        <Image Width="16" Height="16" Source="/SLWebApp;component/img/Icon-Search.png"></Image>
                        <TextBlock x:Name="btnBulk_Modefy" MouseLeftButtonDown="btnBulk_Modefy_MouseLeftButtonDown"  Padding="3,6" Cursor="Hand">修改保存</TextBlock>
                    </StackPanel>
                </Border>
                <Border Margin="0,5,0,0" BorderThickness="1" BorderBrush="#b4b4b4" CornerRadius="1" >
                    <Grid >
                        <Grid.RowDefinitions>
                            <RowDefinition Height="30" />
                            <RowDefinition Height="30"/>
                            <RowDefinition Height="30"/>
                        </Grid.RowDefinitions>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="80" />
                            <ColumnDefinition Width="41*" />
                            <ColumnDefinition Width="75*" />
                            <ColumnDefinition Width="70"/>
                            <ColumnDefinition Width="115*" />
                            <ColumnDefinition Width="5" />
                        </Grid.ColumnDefinitions>
                        <TextBlock Padding="3,3" Height="22" Grid.Row="0" Grid.Column="0"  HorizontalAlignment="Right">选择类别名：</TextBlock>

                        <TextBox x:Name="txtStyle" Height="22" Grid.Column="1"  Grid.Row="0" Grid.ColumnSpan="4" Padding="30,2,2,2" />
                        <ComboBox x:Name="comboxBoxBigStyle" Grid.Column="1" Height="22" Width="24" HorizontalAlignment="Left">
                            <controls:TreeView x:Name="treeType" BorderThickness="0" SelectedItemChanged="treeType_SelectedItemChanged" />
                        </ComboBox>

                        <TextBlock Padding="3,3" Height="22" Grid.Row="1" Grid.Column="0"  HorizontalAlignment="Right">件数：</TextBlock>
                        <TextBox x:Name="txtCount"  Grid.Row="1" Grid.Column="1" Height="22" Grid.ColumnSpan="2" Margin="0,4" />

                        <TextBlock Padding="3,3" Height="22" Grid.Row="1" Grid.Column="3"  HorizontalAlignment="Right">毛重：</TextBlock>
                        <TextBox x:Name="txtWeight"  Grid.Row="1" Grid.Column="4" Height="22"/>

                        <TextBlock Padding="3,3" Height="22" Grid.Row="2" Grid.Column="0"  HorizontalAlignment="Right">体积：</TextBlock>
                        <TextBox x:Name="txtVolumn" Height="22" Grid.Row="2" Grid.Column="1" Grid.ColumnSpan="2" Margin="0,4" />
                    </Grid>
                </Border>
                <Border Height="5" />
            </StackPanel>

            <sdk:DataGrid x:Name="dataGridBlukBox" Grid.Row="3" IsReadOnly="True" SelectionChanged="dataGridBlukBox_SelectionChanged"  Grid.Column="2" Height="Auto" MinHeight="250" MaxHeight="250"  AutoGenerateColumns="False" HorizontalContentAlignment="Center">
                <sdk:DataGrid.Columns>
                    <sdk:DataGridTextColumn Header="类别" Width="10*" Binding="{Binding RV_MEANING}"  />
                    <sdk:DataGridTextColumn Header="件数" Width="10*" Binding="{Binding VAG_PKG}"  />
                    <sdk:DataGridTextColumn Header="毛重" Width="10*" Binding="{Binding VAG_TON}"  />
                    <sdk:DataGridTextColumn Header="体积" Width="10*" Binding="{Binding VAG_VOL}"  />
                </sdk:DataGrid.Columns>
            </sdk:DataGrid>
        </Grid>
    </toolkit:BusyIndicator>
</controls:ChildWindow>